package com.ruoyi.emergency.service.impl;

import java.util.List;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; //添加
import com.ruoyi.emergency.domain.EmergencyProfessor;
import com.ruoyi.emergency.mapper.EmergencyProfessorMapper;
import com.ruoyi.emergency.service.IEmergencyProfessorService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 应急救援专家Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-11-17
 */
@Service
public class EmergencyProfessorServiceImpl extends ServiceImpl<EmergencyProfessorMapper, EmergencyProfessor> implements IEmergencyProfessorService //修改
{
    @Autowired
    private EmergencyProfessorMapper emergencyProfessorMapper;

    /**
     * 查询应急救援专家
     * 
     * @param id 应急救援专家主键
     * @return 应急救援专家
     */
    @Override
    public EmergencyProfessor selectEmergencyProfessorById(Long id)
    {
        return emergencyProfessorMapper.selectEmergencyProfessorById(id);
    }

    /**
     * 查询应急救援专家列表
     * 
     * @param emergencyProfessor 应急救援专家
     * @return 应急救援专家
     */
    @Override
    public List<EmergencyProfessor> selectEmergencyProfessorList(EmergencyProfessor emergencyProfessor)
    {
        return emergencyProfessorMapper.selectEmergencyProfessorList(emergencyProfessor);
    }

    /**
     * 新增应急救援专家
     * 
     * @param emergencyProfessor 应急救援专家
     * @return 结果
     */
    @Override
    public int insertEmergencyProfessor(EmergencyProfessor emergencyProfessor)
    {
        return emergencyProfessorMapper.insertEmergencyProfessor(emergencyProfessor);
    }

    /**
     * 修改应急救援专家
     * 
     * @param emergencyProfessor 应急救援专家
     * @return 结果
     */
    @Override
    public int updateEmergencyProfessor(EmergencyProfessor emergencyProfessor)
    {
        return emergencyProfessorMapper.updateEmergencyProfessor(emergencyProfessor);
    }

    /**
     * 批量删除应急救援专家
     * 
     * @param ids 需要删除的应急救援专家主键
     * @return 结果
     */
    @Override
    public int deleteEmergencyProfessorByIds(Long[] ids)
    {
        return emergencyProfessorMapper.deleteEmergencyProfessorByIds(ids);
    }

    /**
     * 删除应急救援专家信息
     * 
     * @param id 应急救援专家主键
     * @return 结果
     */
    @Override
    public int deleteEmergencyProfessorById(Long id)
    {
        return emergencyProfessorMapper.deleteEmergencyProfessorById(id);
    }
}
